home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
HyperLib 1997 Winter - Disc 1
/
HYPERLIB-1997-Winter-CD1.ISO.7z
/
HYPERLIB-1997-Winter-CD1.ISO
/
第1特集Plug-in
/
Photoshop
/
ChrisFilters3.sit
/
ChrisFilters3
/
Read Me Chris' Filters
next >
Wrap
Text File
|
1995-12-18
|
15KB
|
317 lines
All of these filters are Copyright 1995 by Chris Cox all right reserved.
Permission is given to upload this archive (in its entirety) to online
services that do NOT charge for specific downloads. If you wish to
distribute this archive or these filters elsewhere, contact me.
I'm releasing these filters as shareware. If you find them useful, I'd
appreciate a donation of whatever you think is appropriate (How much are
they worth to you?). Send checks to the address below.
Good news since the last release: I now have a full-time job with
Adaptive Solutions, Inc. I will keep using my parents' address for shareware
payments, since I may be apartment hopping for a few years. I'm still
writing some custom filters - but my free time is now more limited.
This release supports the Photoshop 3.0 filter specifications.
These filters will not work correctly with older versions of Photoshop or
compatable programs that do not accept Photoshop 3.0 plug-ins.
Have fun playing with them. Let me know how useful and/or buggy
you find them.
Chris Cox
110 Oakland Circle
Madison, AL 35758-8663
ccox@teleport.com
http://www.teleport.com/~ccox/
ChrisCox@aol.com
These filters are provided as FAT binaries containing both PPC and 68k code.
For 68k machines, you must have a 68020 or newer processor but do not need
an FPU. None of these filters use or require a math coprocessor (FPU).
AddRight1 (Other menu)
AddRight2 (Other menu)
These both add the pixel values across the image and store the sum
modulus 255. AddRight1 treats each pixel as a number from 0 to 255.
AddRight2 treats each pixel as a number from -127 to 128. Their effect on
photographs isn't particularly interesting, but they can be interesting on
low contrast images. These were originally written as a test for something
else I am working on - but I figured that someone out there will find a
productive use for them (I thought nobody would ever find a use for Plaid,
but at least 2 magazines have).
NoCopyVertical (Stylize menu)
NoCopyDiagonal (Stylize menu)
The technical explanation is that they produce an approximate 50% line screen
with the line width depending on the value of the pixels in the source image.
The more useful explanation is that I wanted a way to produce those
'impossible to copy' patterns that appear in the background of many checks
and secure documents. The Vertical version produces vertical lines and the
Diagonal version produces (you guessed it) diagonal lines.
To get an 'impossible to copy' pattern: start with a grayscale image, fill
it with a single value (preferably something between 20% and 80%), now
make a selection (type tool, lasso, whatever), fill the selection with a
different value, deselect, and run one of the filters. All of the image
will be just about a 50% gray screen, but with the background and the
selection at different line frequencies. If one of the regions is a coarse
line frequency and the other is a higher frequency, then a high resolution
print will not photocopy very well. Be warned, laser printers also don't
reproduce fine patterns very well.
BitPatterns (Stylize menu)
Swirlies (Stylize menu)
Code-wise these are pretty similar to to NoCopy filters. They both use a
combination of pixel position and value to produce a binary (black & white)
pattern. The patterns may not be especially useful by themselves, but they
can be further manipulated to produce interesting textures.
Hairy Noise (Noise menu)
This was an intermediate stage in the development of something else - but it
produces some interesting noise patterns. Depending on the parameter you
enter, it can look like long hair, a waterfall, felt, all sorts of stuff.
Colorize to taste.
SmudgeRight (Blur menu)
This simply smudges the image to the right by a specified percentage. I wanted
a way to do this, and the KPT Smudge darken and Smudge lighten just didn't
do it. If you need to smudge left, flip the image, apply, flip back.
If you need to smudge up or down, rotate the image, apply, and rotate it back.
Average (Blur menu)
This filter calculates the average color within the selected region, then fills
the selection with that color. It's that simple. Try it on some odd pictures
and shapes - it really IS that simple.
Basically I wanted a way to turn photographs into stained-glass style pictures,
but couldn't find a quick way to do it. Now I make odd selections with the
lasso and then average the color within the selection - these become the glass
panes. When I finish creating panes I increase the color saturation then
'find edges' to create a mask for the leading between panes.
Checkers (Other menu)
Here is a quick way to get a regular checkered pattern over an image. It uses
the foreground or background color to draw the blocks, and you specify the
width and height. Wherever it doesn't draw color, it copies the existing image.
For a 'real' checkerboard:
new image
256x256
RGB
select red as the background color
select all
hit the delete key to clear the image to red
select black as the foreground color
Filter->Other->Checkers
width 32
height 32
foreground color
it's done
Also try setting the width and height to 1 and the color to black or white
for a really bad screening effect.
BitShift (Other menu)
It takes the bytes that make up the image and rotates them by a specified
number of bits (1-7). If you don't understand bit operations -- don't worry
about it. Just try the filter on some simple (but varied) images. I suggest
using a grayscale image (for speed) and creating a gray ramp somewhere in the
image (to show you what is going on) and then use BitShift with a value of 1.
Then use it again -- this is equivalent to using BitShift with a value of 2.
Keep going until you get the original image back. Now you should have a feel
for what the filter really does.
note: Shifting by 8 bits is identical to not doing the rotation at all, and
shifting by 7 bits is equal to shifting by -1 bits.
Grid (Other menu)
The filter quickly puts a grid over the existing picture, with specified
spacing and widths for the horizontal and vertical lines. You can use the
foreground or background color for the grid lines. This was written as a
quick and dirty way to get calibration grids for image processing. Laying
down a grid over a scanned photo is a great way to play with 'Displace' and
other distortion filters.
Add More Noise (Noise menu)
This is an extension on Adobe's 'Add Noise' filter, and gives you more control
and options. In RGB mode you can specify how much noise to add to each channel
and which channels will be modified. In RGB mode the HSV noise is added first,
then the RGB, and gray noise (a single value added to all channels) last.
In CMYK mode, you can only control the amount of noise for each of the CMYK
channels (sorry, no HSV here, yet).
One big advantage to this filter - the Hue noise will wrap around the color
cone, which won't happen if you convert an image to HSB to add noise and
convert it back.
NOTE: In RGB mode, adding noise in any of the Hue, Saturation, or Value
channels will make the filter run slower (due to the RGB->HSV->RGB conversion).
Total Noise (Noise menu)
This filter replaces the selected region of the image with random noise.
Adobe's 'Add Noise' filter does just what it says -- add noise to the values
that are already present. 'Add Noise' with it's maximum value of 999 still
won't give you fully random, uniform noise. This filter will provide that
noise. I use it to generate (with a lot of other operations) random
backgrounds or to multiply with existing images to add texture.
NOTE: if you used an older version of my filters, the file was named
'Noise Filter' instead of 'Total Noise'. If you have a plug-in named
'Noise Filter', then you need to remove it from your plug-ins folder.
(some people got confused because the filter and file had different names)
Fractal Noise (Noise menu)
It fills the current selection with fractal noise (looks sorta like clouds or
crumpled paper). It calculates only one channel worth of noise at a time, so
it fills color images with gray noise. You can do a lot with this by
altering the color with 'Hue/Saturation', 'Arbitrary Curves' or 'Levels'.
Try this - 'Fractal Noise', 'Solarize', 'Equalize', 'Solarize', 'Equalize',
'Blur'(to clean up the edges). Makes a nice, quick marble or lightning.
Yes, this one is the slowest of my filters - it does a LOT of calculation
to get that noise. It's not as simple as it looks.
I have added the ability to choose types of fractal noise. Each of the modes
does about the same number of calculations, but results in different types
of noise (and vastly different appearances). The 'Add' mode is the same as
the first version of the filter.
Plaid (Noise menu)
Here is an example of what happens when programmers type too fast: they get
unexpected results. This was a silly mistake that I decided to keep (and
clean up to remove what it was supposed to do). It makes symmetrical (by
powers of 2) patterns in each available color channel. Not guaranteed to be
useful to anyone except golfers and upholstry fabric designers.
Psycho (Stylize menu)
This generates and applies random sine-wave based color maps to RGB and CMYK
images. Bring up a grayscale image and change the mode to RGB, then hit
'Psycho'. Now 'Undo' and hit command-F. Keep doing this until you understand
what it's doing. This works best on large areas of fairly continuous tones
(ie: blurred or smooth). Another neat trick is to blur an existing color
image (Gaussian Blur, 6 pixels), then use 'Psycho' - Instant interference
fringes (oil slicks to the rest of the world)!
UnAlias (Blur menu)
Quick summary: it blurs edges and corners. It uses an edge detector and a
threshold value to decide if and how much to blur each pixel. You specify the
threshold and the maximum amount of blur to apply. This can be used to
remove 'jaggies' from imported images - but it takes a bit of practice to
know how, when, and where to use.
Edge3x3 (Custom menu)
This is a simple edge detector that I occasionally find useful (more so than
'Find Edges'). It's quick, it's simple, it doesn't take long to learn.
This is a 'Custom' filter that I hard coded. On a 512x512 Grayscale image,
the 'Custom' filter takes about 20 seconds. My version takes 8.4 seconds
(on my old, slow MacII).
Erode (Custom menu)
Reduces the area of dark regions within the image. It compares the sum of the
pixels in the region to a threshold value, then sets the pixel to white if the
total exceeds the threshold, else it leaves the old pixel value. You'll
probably have to play with this one, and I suggest thresholding your first
few test images to better understand what's happening. Apply the filter
repeatedly to an image and watch.
Dilate (Custom menu)
This one enlarges the dark regions of the image. It also compares the sum of
the pixels to a threshold value, but a bit differently. Again, play with it
(basically, that's the only good way to ever learn what a filter/program
does -- the manual or instructions never do them justice), and again I
suggest thresholding the first few images.
Skeleton (Custom menu)
This is actually a thinning algorithm based on work by Zhang and Suen(CACM,
March 1984, 236-239). The filter reduces the dark areas of the image (dark
defined by a threshold) to their approximate centerline or skeleton.
You guessed it -- just try the filter. This one will need to be applied
repeatedly, until the 'skeletons' are as thin as you want/need them.
The Erode, Dilate and Skeleton filters are used in image processing packages,
usually on binary images but with thresholds they can be useful with grayscale
or color. The thinning algorithm is sometimes used as a preprocessor for image
recognition algorithms (such as OCR). I use these filters for image processing,
but you may find other uses for them (they can be used to generate some really
weird effects).
ColorKey (Video menu)
It turns the filtered image into a mask based on the current foreground color.
If you select blue for the foreground, then the filter will leave the image
white wherever the image was near blue, and black where it wasn't. The filter
takes a tolerance value which ranges from 0 to 999. Try selecting a color
from a varied image and using the filter with different tolerance values.
This filter operates by adding the absolute difference between the foreground
color and the pixel value (ie: Rdiff + Gdiff + Bdiff) and then comparing that
against the tolerance. In theory 765 is the greatest possible color
difference.
ChromaKey (Video menu)
This also generates a mask based on the current foreground color, but uses a
different technique (and is a little slower). If you select a pure blue for
the foreground color and use small tolerance values, then the filter will
make the image white (or gray) where the image was very near pure blue, and
black where the image had a different color, saturation, or value. You will
need to enter three tolerance values: one each for Hue, Saturation, and Value.
Again, try this with an arbitrary color and a varied color image.
Beware of red hues, black, white, and grays: they all have a hue value of 0,
and will match one another. This is due to the numerical conventions of the
HSV color space. (and I haven't figured out a good way around it)
This filter actually converts the RGB values into HSV, then compares each
component separately using the tolerance values. All three channels range
from zero to 255. Setting all of the tolerances to 255 should match all
colors.
At the moment, this filter is limited to operating on RGB images --
HSV keying on Grayscale is pointless, and CMYK->HSV conversion isn't that
straightforward. When I get inspired I'll probably add the CMYK code.
FastKey (Video menu)
A filter that makes a mask based on a single RGB value (the current foreground
color). This filter has absolutely NO tolerance.
You can use FastKey, ColorKey or ChromaKey to do video compositing, they just
have different quirks and will usually give different results. Practice is
needed to know when to use which one, and with what tolerances. After using the
filters, you use the Image->Calculate->Composite command to do the actual
composite of foreground and background(live and insert/graphics) images.